<?php
ini_set('display_errors', 1); 
error_reporting(E_ALL);

ob_start();
include_once 'classes/Login.php';
include_once 'classes/controls/LoginForm.php';
session_start();

//Test Amaçlı
//$isAuthenticated = false;
//$_SESSION['isAuthenticated'] = $isAuthenticated;
//Login Class da halledilecek

//$user = new User();
//Login::Authenticate($user);

echo "Anasayfa<br>";
$login = new Login();

if(!$login->isAuthenticated())header ("Location:login.php");
else {
	if(isset($_SESSION['NextPage'])){
		$nextpage = $_SESSION['NextPage'];
		switch ($nextpage){
			//case "CampaignDetails": include_once 'deneme2.php';//campaign.php';
		}
	}else include_once 'main.php';
}
?>